package com.baiduspring.utils.security;

import org.apache.commons.codec.binary.Base64;

public class Base64Utils {
    public static String encode(String code) {
        return Base64.encodeBase64String(code.getBytes());
    }

    public static String decode(String code) {
        return new String(Base64.decodeBase64(code.getBytes()));
    }
}
